import { request } from "../request";
export interface LoginRes {
    code: number;
    message: string;
    data: Record<string, string>;
    timestamp: Record<string, unknown>;
}
const loginAPI = async (data:{
    username:string,
    password:string,
}) :Promise<LoginRes>=> {
    return request("/api/auth/login",{
        method: "post",
        headers: {"Content-Type":"application/json",},
        data: data,
    })
}

export default loginAPI;